getFileType
Gets the file type of an existing Mac OS file.
public static final MRJOSType getFileType ( File file) throws IOException;
file
- The file whose file type you want to obtain.
- method result
- The 4-byte file type of the file.
DISCUSSION
On the Mac OS platform, a file type is a 4-byte character constant that identifies the type of file to the Finder (for example,'TEXT'
for a text file, or'APPL'
for an application). This method throwsIOException
if the desired file cannot be found.SEE ALSO
ThesetFileTypeAndCreator
method (page 37).The
setFileType
method (page 38).The "Finder Interface" chapter in Inside Macintosh: Macintosh Toolbox Essentials for information about file types.